package com.zhuiyun.pm.sys.homePage.service;

import com.zhuiyun.pm.sys.homePage.entity.SysChartEntity;
import com.zhuiyun.pm.sys.homePage.entity.dto.BarChartDTO;
import com.zhuiyun.pm.sys.homePage.entity.dto.PieChartDTO;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 *
 * @author: HKY
 * @date: 2023/3/21 16:30
 * @return null
 * @Description: 主页数据统计
 */
public interface HomePageService {

    /**
     *
     * @author: HKY
     * @date: 2023/3/21 16:48
     * @return java.util.List
     * @Description: 柱状图OR折线图
     */
    Map<String, Object> getBarChart(String sqlStr,String chartType,String operationType);

    /**
     *
     * @author: HKY
     * @date: 2023/3/21 16:48
     * @return java.util.List
     * @Description: 饼状图
     */
    List<PieChartDTO> getPieChart(String sqlStr,String operationType);

    /**
     *
     * @author: HKY
     * @date: 2023/3/21 16:48
     * @return java.util.List
     * @Description: 获取图表集合
     */
    List<SysChartEntity> getChartList();

    /**
     *
     * @author: HKY
     * @date: 2023/3/21 16:48
     * @return java.util.List
     * @Description: 漏斗图
     */
    HashMap<String, Object> getFunnelChart(String sqlStr,String operationType);

    /**
     *
     * @author: HKY
     * @date: 2023/3/30 15:11
     * @param id
     * @return int
     * @Description: id删除
     */
    int deleteByID(String id);

    /**
     *
     * @author: HKY
     * @date: 2023/3/30 15:11
     * @param sysChartEntity
     * @return int
     * @Description: 修改
     */
    int updateChart(SysChartEntity sysChartEntity);

}
